/**
 * 这是手机号码修改
 */

import { Steps } from 'antd';

const { Step } = Steps;
import styles from './change.less';
import PhoneStepOne from './phoneStepOne';
import PhoneStepTwo from './PhoneStepTwo';
import { useState } from 'react';
export default function IndexPage(props) {
  const [nowStep, setNowStep] = useState(0);
  return (
    <div className={styles.selectWrap}>
      <div className={styles.selectHead}>
        <span className={`${styles.selectItem} ${styles.selectItemAct}`}>
          手机号码修改
        </span>
        <span
          onClick={() => {
            props.setShowType(2);
          }}
          className={styles.selectItem}
        >
          密码修改
        </span>
      </div>
      <div className={styles.stepWrap}>
        <Steps current={nowStep}>
          <Step title="账号验证" description="请填写相关信息" />
          <Step title="重置手机号" description="请输入手机号信息" />
        </Steps>
      </div>
      <div>
        {nowStep === 0 ? (
          <PhoneStepOne setNowStep={setNowStep}></PhoneStepOne>
        ) : (
          <PhoneStepTwo setNowStep={setNowStep}></PhoneStepTwo>
        )}
      </div>
    </div>
  );
}
